package com.cy.lib.redis.core.factory;

import org.apache.commons.pool2.BasePooledObjectFactory;
import org.apache.commons.pool2.PooledObject;
import org.apache.commons.pool2.impl.DefaultPooledObject;
import org.msgpack.MessagePack;

public class MsgPackFactory extends BasePooledObjectFactory<MessagePack>{

	@Override
	public MessagePack create() throws Exception {
		return new MessagePack();
	}

	@Override
	public PooledObject<MessagePack> wrap(MessagePack obj) {
		return new DefaultPooledObject<MessagePack>(obj);
	}

}
